<?php
header('content-type:text/html; charset=utf-8');
session_start();
if(isset($_SESSION['user'])){
	print_r("<h3>通讯录界面</h3>");
	print_r("<a href='logout.php'>退出</a>");
}else{
	header('Refresh:2;url=/login.php');
	die('<h3>请先登录</h3><a>返回重新登录</a>');
}
?>
<!DOCTYPE html>
<html>
   <head>
      <title>Bootstrap 模板</title>
	  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" charset="UTF-8" >
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <link href="css/bootstrap.min.css" rel="stylesheet">
      <script src="js/jquery-1.11.1.min.js"></script>
      <script src="js/bootstrap.min.js"></script>
      <!--[if lt IE 9]>
         <script src="js/html5shiv.js"></script>
         <script src="js/respond.min.js"></script>
      <![endif]-->
   </head>
   <body>
   	<div class="container">
   		<div class="col-xs-5">
       <nav class="navbar navbar-default">
     	<div class="row">
     		<div class="col-xs-8">
     			<form action="#" class="navbar-form">
     				<div class="input-group">
     					<input class="form-control" name="text" placeholder="搜索"/>
						<div class="input-group-btn">
							<button type="submit" class="btn btn-default" style="height:34px;">
								<span class="glyphicon glyphicon-search"></span>
							</button>
						</div>
					</div>
				</form>
			</div>
			<ul class="nav navbar-nav">
		        <li class="dropdown">
		          <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><span class="glyphicon glyphicon-th-list"></span>&nbsp;通讯录 <span class="caret"></span></a>
		          <ul class="dropdown-menu">
		            <li><a href="user.php">添加</a></li>
		            <li><a href="main.php">列表</a></li>		       		        
		          </ul>
		        </li>
      		</ul>

		</div>
	</nav>
	<div class="panel panel-default">
		<div class="panel-heading">
			<div class="panel-title">通讯录列表</div>
		</div>
		<div class="list-group">
			<a class="list-group-item"><span class="glyphicon glyphicon-user"></span>为了谁</a>
			<a class="list-group-item"><span class="glyphicon glyphicon-user"></span>为了谁</a>
			<a class="list-group-item"><span class="glyphicon glyphicon-user"></span>为了谁</a>
			<a class="list-group-item"><span class="glyphicon glyphicon-user"></span>为了谁</a>
			<a class="list-group-item"><span class="glyphicon glyphicon-user"></span>为了谁</a>
		</div>
	</div>
	</div>
	</div>
   </body>
</html>